<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
	
	</head>
	<body>
<input name="jisuanyng" type="button" value="计算" onclick="jisuan()" />
	<script type="text/javascript">
			
		function jisuan(){
				var fi=parseInt(prompt("请输入第一个数"));
			var fi1=parseInt(prompt("请输入第二个数"));
			var fi3=prompt("请输入运算符号");
			var fc;
			switch (fi3){
				case "+":
				fc=fi+fi1;
					break;
				case "-":
				fc=fi-fi1;
					break;case "*":
				fc=fi*fi1;
					break;case "/":
				fc=fi/fi1;
					break;
			}
			document.write(fi+""+fi3+""+fi1+"的结果是"+fc);
		}
		</script>
	</body>
</html>
